/******************************************************************************
 * Copyright (C) 2011 ShenZhen ComTop Information Technology Co.,Ltd
 * All Rights Reserved.
 * 本软件为深圳康拓普开发研制。未经本公司正式书面同意，其他任何个人、团体不得使用、
 * 复制、修改或发布本软件.
 *****************************************************************************/

package com.code.common.propertyeditor;

import java.net.URI;

import org.springframework.beans.PropertyEditorRegistrar;
import org.springframework.beans.PropertyEditorRegistry;

/**
 * 自定义属性编辑器注册
 * 
 * @author 周振兴
 * @since 1.0
 * @version 2011-6-9 周振兴
 */
public final class CustomPropertyEditorRegistrar implements PropertyEditorRegistrar {
    
    /**
     * @param registry registry
     * @see org.springframework.beans.PropertyEditorRegistrar#registerCustomEditors(org.springframework.beans.PropertyEditorRegistry)
     */
    public void registerCustomEditors(PropertyEditorRegistry registry) {
        registry.registerCustomEditor(String.class, new StringPropertyEditor());
        registry.registerCustomEditor(int.class, new IntPropertyEditor());
        registry.registerCustomEditor(Integer.class, new IntPropertyEditor());
        registry.registerCustomEditor(URI.class, new URIPropertyEditor());
    }
}